<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<title>律师事务所管理系统-JSJ-v1.0</title>
		<!--  ext式样库 -->
		<link type="text/css" rel="stylesheet"
			href="ext/resources/css/ext-all.css">
		<link rel="stylesheet" type="text/css" href="css/style.css" />
		<!--  ext基础类库 -->
		<script type="text/javascript" src="ext/adapter/ext/ext-base.js"></script>
		<!--  ext核心类库 -->
		<script type="text/javascript" src="ext/ext-all-debug.js"></script>
		<script type="text/javascript"
			src="ext/source/locale/ext-lang-zh_CN.js"></script>
		<script type="text/javascript" src="js/themeChange.js"></script>
		<script type="text/javascript" src="js/DWRTreeLoader.js"></script>
		<script type="text/javascript" src="js/dwrproxy.js"></script>
		
		<script type='text/javascript' src='dwr/interface/treeNodeFactory.js'></script>
		<script type='text/javascript' src='dwr/engine.js'></script>
		<script type='text/javascript' src='dwr/util.js'></script>
				<script type='text/javascript' src='/dwr/interface/DeptInfoRequest.js'></script>
		<script type="text/javascript">
Ext.BLANK_IMAGE_URL = 'ext/resources/images/default/s.gif';
Ext.onReady(function() {

		var loader = new Ext.ux.DWRTreeLoader( {
			dwrMethod : treeNodeFactory.getTreeNodesByFatherId
		});
		var root = new Ext.tree.AsyncTreeNode( {
			id : "root",
			text : "律师事务所管理系统",
			expanded : true//默认展开根节点
		});
 
 // 右边具体功能面板区
 var contentPanel = new Ext.TabPanel({
	region : 'center',
  enableTabScroll : true,
  activeTab : 0,
  items : [{
   id : 'homePage',
   title : '首页',
   autoScroll : true,
   html : '<div style="position:absolute;color:#000000;top:40%;left:40%;"><h1>欢迎使用JSJ开发的人和人律师事务所管理系统</h1></div>'
  }]
 });
 
             
 new Ext.Viewport({
  layout : 'border', // 使用border布局
  defaults : {
   activeItem : 0
  },
  items:[
  		contentPanel,
  	{
        collapsible: true,
		contentEl:'top-logo',
		region: 'north',//指定子面板所在区域为north
		height: 100
		},
		{
		xtype:'treepanel',
		region:"west",
	    width:200,
	    split:true,
	    collapsible:true,
	    title : '功能菜单',
   		 root: root,
   		 loader: loader,
   		   listeners : {
		   'click' : function(node, event) {
		    event.stopEvent();
		    var n = contentPanel.getComponent(node.id);
		    if (!n) { // //判断是否已经打开该面板
		     n = contentPanel.add({
		      'id' : node.id,
		      'title' : node.text,
		      closable : true,
		      autoLoad : {
		       url : node.attributes.url,
		       scripts : true
		      } // 通过autoLoad属性载入目标页,如果要用到脚本,必须加上scripts属性
		     });
		    }
		    contentPanel.setActiveTab(n);
		   }
		  },
		tbar : [
				'皮肤选择：',
				{
					xtype : 'themeChange',
					width : 120,
					listWidth : 120
				},
				'->'
			]
		},{
		    region:"south",
		    height:25,
		    title : '开始'
		  }
		]
 });
});
</script>
	</head>
	<body>
		<div id='top-logo'>
			<div id='logo'>
				<img src="images/law.jpg" />
			</div>
			<div id='banner'>
				<img src="images/ico_3.gif" />
				注销&nbsp;
				<img src="images/ico_5.gif" />
				设置&nbsp;
				<img src="images/ico_7.gif" />
				帮助&nbsp;
				<img src="images/ico_9.gif" />
				关于
				<br />
				<br />
		
欢迎<%=session.getAttribute("role")%>  <%=session.getAttribute("userName")%>登录本系统
	</div>
		</div>
	</body>
</html>
